package com.example.jopewars;

import javax.swing.JPanel;
import javax.swing.border.TitledBorder;
import javax.swing.JList;
import java.awt.BorderLayout;
import javax.swing.AbstractListModel;

public class MarketplacePanel extends JPanel implements GameStateChangedListener {

	private static final long serialVersionUID = 1L;

	/**
	 * Create the panel.
	 */
	public MarketplacePanel() {
		setBorder(new TitledBorder(null, "Marketplace", TitledBorder.LEADING,
				TitledBorder.TOP, null, null));
		setLayout(new BorderLayout(0, 0));

		JList list = new JList();
		list.setModel(new AbstractListModel() {
			String[] values = new String[] { "Cocaine", "Heroin", "Weed",
					"LSD", "Acid" };

			public int getSize() {
				return values.length;
			}

			public Object getElementAt(int index) {
				return values[index];
			}
		});
		add(list);

	}

	@Override
	public void gameStateChanged() {
		

	}

}
